#ifndef ALGORITHM_H
#define ALGORITHM_H

#include "global.h"

void create_gradient(SDL_Color palette[256], SDL_Color c1, SDL_Color c2, 
		int initial_color, int final_color);
void rotate_palette(SDL_Color palette[256], int initial, int final);

// find operating system
#ifdef _AIX
#  define OS "AIX"
#elif AMIGA
#  define OS "AmigaOS"
#elif __BEOS__
#  define OS "BeOS"
#elif __DragonFly__
#  define OS "DragonFly"
#elif __ECOS
#  define OS "eCos"
#elif __FreeBSD__
#  define OS "FreeBSD"
#elif __GNU__
#  define OS "GNU Hurd"
#elif _hpux
#  define OS "HP-UX"
#elif sgi
#  define OS "IRIX"
#elif linux
#  define OS "Linux"
#elif __Lynx__
#  define OS "LynxOS"
#elif macintosh
#  define OS "MacOS"
#elif __APPLE__ & __MACH__
#  define OS "Max OS X"
#elif __minix
#  define OS "MINIX"
#elif MSDOS
#  define OS "MSDOS"
#elif _WIN32
#  define OS "Windows"
#elif _WIN32_WCE
#  define OS "Windows CE"
#elif __NetBSD__
#  define OS "NetBSD"
#elif __OpenBSD__
#  define OS "OpenBSD"
#elif OS2
#  define OS "OS/2"
#elif __QNX__
#  define OS "QNX"
#elif __QNXNTO__
#  define OS "QNX"
#elif M_I386
#  define OS "SCO OpenServer"
#elif sun
#  define OS "Solaris"
#elif __SYMBIAN32__
#  define OS "Symbian OS"
#elif sco
#  define OS "UnixWare"
#elif VMS
#  define OS "VMS"
#elif __MVS__
#  define OS "z/OS"
#elif __unix__
#  define OS "Unix"
#else
#  define OS "Operating System"
#endif

#endif
